﻿using System;
using System.Collections.Generic;
using System.Text;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Audio;
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.GamerServices;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Input;
using Microsoft.Xna.Framework.Media;
using Microsoft.Xna.Framework.Net;
using Microsoft.Xna.Framework.Storage;
using System.Xml;

namespace GameBanChim_Version1
{
    public class BirdManager : EntityManager
    {
        public override void InitPrototypes(ContentManager contenManager)
        {
            _xmlInfo = @"./XML/Bird.xml";
            XmlDocument _doc = new XmlDocument();
            _doc.Load(_xmlInfo);
            _nprototype = _doc.DocumentElement.SelectNodes("//Bird").Count;
            _prototype = new VisibleGameObject[_nprototype];
            for (int i = 0; i < _nprototype; i++)
            {
                _prototype[i] = new Bird();
                _prototype[i].Init(contenManager, i, _xmlInfo);
            }
        }
    }
}
